val age=List(1,2,3,65,22,13,10,20)

val (s,b)=age.partition(_ <18)
